package com.cn.jasyptdbtwo.dao;


import com.cn.jasyptdbtwo.pojo.PriceList;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;


@Mapper
@Repository
public interface PriceListMapper {

    List<PriceList> selectAllPriceList();


    @Delete("delete from productsales where id = #{id} ")
    int deletePriceList(@Param("id") Integer id);


    void insterPriceList(PriceList priceList);

    @Select("select count(*) from productsales where id = #{id} ")
    int selectCountPriceList(@Param("id") Integer id);


}
